package com.wwl.springcloud.controller;

import com.wwl.springcloud.dto.CommonResult;
import com.wwl.springcloud.dto.Payment;
import com.wwl.springcloud.service.PaymentService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author wwl
 * @version 1.0
 * @date 2021/8/19 19:51
 * @description:
 */
@RestController
public class PaymentController {
    // OpenFeign
    @Resource
    private PaymentService paymentService;

    @GetMapping(value = "/consumer/paymentSQL/{id}")
    public CommonResult<Payment> paymentSQL(@PathVariable("id") Integer id) {
        return paymentService.paymentSQL(id);
    }
}
